<?php
/*
*All rights reserved: Json.
*Links:http://www.liyaoquan.cn.
*Links:http://imarkchina.cn.
*Links:http://www.imarkchina.cn.
*/

/**
 * 博客前台列表控制器，负责，业务流程判断
 */
Class ListAction extends Action{

	/**
	 * 博客首页列表
	 * @return [type] [description]
	 */
	Public function index(){
		$getp = trim(G('get.p'));
		$id = (!empty($getp)) ? (int)G('get.p') : 1;
		$lid = G('get.lid');
		C('TPLCACHENAME', 'list-'.$lid.$id);
		C('TPLCACHEING', C('CHECKCACHEING'));
		if (!$this->isCache()) {
			$M = M('List')->getList(G('get.lid'));
			$this->assign('check', $M['check']);
			$this->assign('lid', $M['lid']);
			$this->assign('list', $M['list']);
			$this->assign('page', $M['page']);
		}
		$this->display();
	}
}